package com.fjc.cloud.order.feign;

import com.fjc.cloud.user.entity.User;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;

/**
 * 声明一个Feign接口，用于调用用户服务
 */
@FeignClient(name = "my-cloud-user")
public interface UserFeignClient {

    @GetMapping("/api/user/findUserById/{userId}")
    User findUserById(@PathVariable("userId") Long userId);
}
